How to Check if Port 25 is Blocked
If you are able to receive mail without issue, but are unable to send mail from your mail client and you are certain your outgoing mail server settings are correct, you might be blocked by your ISP from connecting on port 25.
The default port for SMTP (sending mail) is port 25. Some ISPs block access to port 25 in order to try to avoid some issues with spammers. However, this can also block you from being able to connect to your mail server to send mail through your domain. Alternately, you may have port 25 blocked in your local router or cable modem. This article will explain how to check if port 25 is blocked from where ever you are and what you can do about it.
How to Check if Port 25 is Blocked
Here is how you can check to see if port 25 is blocked. Follow the directions for the OS that you are using locally (not on the mail server itself).
Windows 7/8/10
-
Click the Windows icon in the lower left or press the Windows key.
-
Type cmd with the menu open.
-
Press Enter or select Command Prompt (or cmd on Windows 7/8) with your mouse.
-
Install the telnet program by typing this into the command prompt and pressing Enter: pkgmgr /iu:”TelnetClient”
-
Wait for few moments while telnet is installed.
-
On Windows 7 and 8, you may need to close the command window and follow steps 1-3 above to reopen the command prompt. This step is not necessary in Windows 10.
⚠️ If you have problems installing telnet via the command prompt, you can navigate to Control Panels from the Windows menu, then find Programs and Features section and select Turn Windows Features On or Off.
Look for Telnet Client (not Telnet Server) and make sure the box next to it is checked and then click OK.
-
Type telnet MAILSERVER 25 (replace MAILSERVER with your mail server (SMTP) which may be something like server.domain.com or mail.yourdomain.com).
-
Press Enter.
-
If you aren't blocked, you will now see a connection notification from the remote mail server, which may look something like this:
-
If that port is blocked, you will receive a connection error.
Windows 98/XP/Vista
Here's how to open the command prompt on Windows 98, XP or Vista:
-
Open the Start menu.
-
Select Run.
-
Type cmd.
-
Press Enter.
-
Type telnet MAILSERVER 25 (replace MAILSERVER with your mail server (SMTP) which may be something like server.domain.com or mail.yourdomain.com).
-
Press Enter.
-
If you aren't blocked, you will now see a connection notification from the remote mail server, which may look something like this:
-
If that port is blocked, you will receive a connection error.
MacOS/OS X
To check the accessibility of port 25 on the Mac, we will need to run a command in the Terminal application that is included with every version of OS X.
-
Open the terminal application. It can be found at /Applications/Utilities/Terminal.app. To get there, open the Applications folder and then scroll down and look for the Utilities folder and open that. Then look for the Terminal application and double click on the application to open it.
ℹ️ Depending on your MacOS configuration, the terminal application name may be either Terminal or Terminal.app.
-
This will open a new window with some text in it. Type nc -vz YOURMAILSERVER 25 and press Return. Replace YOURMAILSERVER with the name of your mail server or domain. It may be something like host.domain.com or mail.yourdomain.com.
-
In a few moments, some text should be output to the terminal window. If, at the end, it says something like Connection to YOURMAILSERVER port 25 [tcp/smtp] succeeded! then port 25 is not blocked and you may have other issues preventing you from sending mail. If the result is something like nc: connectx to YOURMAILSERVER port 25 (tcp/smtp) failed: Connection refused then you may be blocked.
What to Do if Port 25 is Blocked
-
Configure your mail client to use port 26 or port 587 for outgoing mail (SMTP) instead. This will usually do the trick.
- On a cPanel server, getting Exim to listen on another port is easy, just check Exim Mailserver on Another Port in the Service Manager feature in WHM and select the port to use (26 is the default), then save changes.
-
Contact your ISP to confirm they are blocking port 25. You'll likely need to change the SMTP port (as in step 1 above) to get around this. ISPs rarely open closed ports for non-business internet clients.
-
If your ISP says they are not blocking port 25 or 587 and you are still having problems sending mail, check your local router or cable modem to see if port 25 is blocked there.
-
If nothing else works, and you have service with HostDime, please contact us and we can investigate.